]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
endSessionDialog: Connect to events in the dialog itself
authorCarlos Garnacho <carlosg@gnome.org>
Tue, 1 Feb 2022 13:12:17 +0000 (14:12 +0100)
committerMarge Bot <marge-bot@gnome.org>
Tue, 1 Feb 2022 14:30:24 +0000 (14:30 +0000)
Connecting to stage events won't work from a modal dialog, since the
grab will take events from the portions of the actor hierarchy above
the grabbing actor.

Connect to events from the dialog itself, so that the end session
dialog can again show the "boot options" easter egg.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2140>

js/ui/endSessionDialog.js

index 1fdbd11b93430f1ba09a8d50f0f573776b3d43c6..9f8bcb1ba161fdce407bfd7ecc6db6fa71838171 100644 (file)
@@ -467,7 +467,7 @@ class EndSessionDialog extends ModalDialog.ModalDialog {
                     label: C_('button', 'Boot Options'),
                 });
                 this._rebootButtonAlt.visible = false;
-                this._capturedEventId = global.stage.connect('captured-event',
+                this._capturedEventId = this.connect('captured-event',
                     this._onCapturedEvent.bind(this));
             }
         }